package com.scheduling.product.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * 工序实体
 *
 * @author 开发团队
 * @since 2025-05-29
 */
@Data
@EqualsAndHashCode(callSuper = false)
@TableName("operation")
public class Operation implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 工序ID
     */
    @TableId(value = "operation_id", type = IdType.ASSIGN_ID)
    private String operationId;

    /**
     * 工艺路线ID
     */
    @TableField("route_id")
    private String routeId;

    /**
     * 工序编号
     */
    @TableField("operation_code")
    private String operationCode;

    /**
     * 工序名称
     */
    @TableField("operation_name")
    private String operationName;

    /**
     * 所需机器类型ID
     */
    @TableField("machine_type_id")
    private String machineTypeId;

    /**
     * 标准作业时间(分钟)
     */
    @TableField("standard_time")
    private Integer standardTime;

    /**
     * 前置工序ID(逗号分隔)
     */
    @TableField("predecessor_ops")
    private String predecessorOps;

    /**
     * 工序序号
     */
    @TableField("sequence_no")
    private Integer sequenceNo;

    /**
     * 创建时间
     */
    @TableField(value = "create_time", fill = FieldFill.INSERT)
    private LocalDateTime createTime;
} 